#include "src/queue/queue.h"

void TestQueue1() {

    Queue q;
    InitQueue(&q);

    Enqueue(&q, 10);
    Enqueue(&q, 20);
    Enqueue(&q, 30);
    Enqueue(&q, 40);
    Enqueue(&q, 50);

    /*Enqueue(&q, 10);
    Enqueue(&q, 10);
    Enqueue(&q, 10);
    Enqueue(&q, 10);
    Enqueue(&q, 10);*/
    TraverseQueue(&q);

    printf("\nDequeueed :%d\n", DeQueue(&q));
    TraverseQueue(&q);

    printf("\nDequeueed :%d\n", DeQueue(&q));
    TraverseQueue(&q);

    printf("\nPeek : %d\n", GetHead(&q));
    TraverseQueue(&q);

    printf("\nEnqueueed  60 :\n");
    Enqueue(&q, 60);
    TraverseQueue(&q);

    ClearQueue(&q);
    TraverseQueue(&q);

    DeQueue(&q);
}

void TestQueue2() {

    Queue q;
    InitQueue(&q);

    for (int i = 0; i < MAX_SIZE + 1; i++)
    {
        Enqueue(&q, i);
    }
    TraverseQueue(&q);
}

int main()
{
    TestQueue1();

    TestQueue2();

    return 0;
}
